//
//  WeatherResultModel.m
//  baodongPro
//
//  Created by feng on 16/3/4.
//  Copyright © 2016年 proper. All rights reserved.
//

#import "WeatherResultModel.h"

@implementation WeatherResultModel
-(instancetype)initWithDictionary:(NSDictionary*)dic
{
    self =[super init];
    if (self)
    {
        /*
         
         @property (nonatomic,strong) NSString*m_WD;
         @property (nonatomic,strong) NSString*m_WS;
         @property (nonatomic,strong) NSString*m_altitude;
         @property (nonatomic,strong) NSString*m_city;
         @property (nonatomic,strong) NSString*m_citycode;
         @property (nonatomic,strong) NSString*m_date;
         @property (nonatomic,strong) NSString*m_h_tmp;
         @property (nonatomic,strong) NSString*m_l_tmp;
         @property (nonatomic,strong) NSString*m_sunrise;
         @property (nonatomic,strong) NSString*m_sunset;
         @property (nonatomic,strong) NSString*m_temp;
         @property (nonatomic,strong) NSString*m_weather;
         */
        self.m_WS=[dic objectForKey:@"WS"];
        self.m_WD=[dic objectForKey:@"WD"];
        self.m_time=[dic objectForKey:@"time"];
        self.m_altitude=[dic objectForKey:@"altitude"];
        self.m_city=[dic objectForKey:@"city"];
        self.m_citycode=[dic objectForKey:@"citycode"];
        self.m_date=[dic objectForKey:@"date"];
        self.m_h_tmp=[dic objectForKey:@"h_tmp"];
        self.m_l_tmp=[dic objectForKey:@"l_tmp"];
        self.m_sunrise=[dic objectForKey:@"sunrise"];
        self.m_sunset=[dic objectForKey:@"sunset"];
        self.m_temp=[dic objectForKey:@"temp"];
        self.m_weather=[dic objectForKey:@"weather"];
        self.m_savedic=dic;
        
        
        self.m_tipArray=[NSMutableArray arrayWithArray:@[@"城市名称",@"日期",
                                                         @"发布时间",
                                                         @"风力",@"风向",
                                                         @"气温",
                                                         @"天气情况",
                                                         @"最高气温",
                                                         @"最低低温",
                                                         @"海拔高度",
                                                         @"日出时间",@"日落时间",@"城市代码",]];
        
        self.m_valueArray=[NSMutableArray arrayWithArray:@[self.m_city,self.m_date,
                                                           self.m_time,self.m_WS,self.m_WD,
                                                           self.m_temp,self.m_weather,self.m_h_tmp,
                                                           self.m_l_tmp,self.m_altitude,self.m_sunrise,
                                                           self.m_sunset,self.m_citycode
                                                           ]];
        
    }
    return self;

}


-(NSMutableDictionary*)dictionaryFormModel
{

    NSMutableDictionary* dic=[NSMutableDictionary dictionary];
    
//    [dic  setValue:self.m_WS forKey:@""];






    return dic;
}








@end
